package com.sqx.modules.pay.controller.app;

import com.baomidou.mybatisplus.core.metadata.TableInfo;
import com.sqx.common.utils.PageUtils;
import com.sqx.common.utils.Result;
import com.sqx.modules.app.annotation.Login;
import com.sqx.modules.pay.dao.UserDramaDetailsDao;
import com.sqx.modules.pay.service.UserDramaDetailsService;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping(value = "/app/drama")
public class UserDramaDetailsController {

    @Autowired
    private UserDramaDetailsService userDramaDetailsService;

    /**
     * 查询用户剧点详情列表
     * @param page
     * @param limit
     * @return
     */
    @Login
    @GetMapping("/getDramaDetailsList")
    public Result getDramaDetailsList(@RequestAttribute Long userId, Integer page, Integer limit){
        return userDramaDetailsService.getDramaDetailsList(userId,page,limit);
    }

    /**
     * 查询剧点列表
     * @return
     */
    @Login
    @GetMapping("/getPointList")
    public Result getPointList(){
        return userDramaDetailsService.getPointList();
    }
}
